<template>
  <h3>06-为 provide / inject 标注类型</h3>
</template>

<script setup lang="ts">
import { inject } from "vue";
import { key } from "../types";

const foo = inject(key, "456");
// foo.toFiexd(2); // TS Error: Property 'toFixed' does not exist on type 'unknown'
foo?.toUpperCase();
console.log("foo-->", foo);
</script>

<style scoped></style>
